package settings.model;

import java.io.File;
import java.util.ArrayList;
import java.util.List;

public class Settings {

	private File lastOutputDir;
	private boolean optionsAlwaysConfirm, optionSubtitleExactMatch, optionSubtitleKeywordMatch, optionNoResultShowItAll;
	private boolean optionsShowOnlyFound, optionsStopOnSearchError;
	private boolean optionsNoRuleMatchTakeFirst,
			optionsAutomaticDownloadSelection;
	private List<MappingBierdopjeScene> mappingList;
	private List<SettingsExcludeItem> excludeList;
	private List<String> qualityRuleList;
	private LibrarySettings movieLibrarySettings;
	private LibrarySettings episodeLibrarySettings;
	private String generalProxyHost;
	private int generalProxyPort;
	private boolean generalProxyEnabled;
	private List<File> defaultIncomingFolders;
	private List<File> localSourcesFolders;
	private boolean optionRecursive;
	private ScreenSettings screenSettings;
	private boolean loginAddic7edEnabled;
	private String loginAddic7edUsername;
	private String loginAddic7edPassword;
	private boolean serieSourceAddic7ed, serieSourceTvSubtitles,
			serieSourcePodnapisi, serieSourceOpensubtitles, serieSourceLocal;
	private boolean autoUpdateMapping;
	private SettingsProcessEpisodeSource processEpisodeSource;

	public Settings() {
		setDefaultIncomingFolders(new ArrayList<File>());
		lastOutputDir = null;
		optionsAlwaysConfirm = false;
		optionsShowOnlyFound = false;
		optionsStopOnSearchError = false;
		optionsNoRuleMatchTakeFirst = false;
		optionsAutomaticDownloadSelection = false;
		mappingList = new ArrayList<MappingBierdopjeScene>();
		qualityRuleList = new ArrayList<String>();
		setExcludeList(new ArrayList<SettingsExcludeItem>());
		movieLibrarySettings = new LibrarySettings();
		episodeLibrarySettings = new LibrarySettings();
		generalProxyHost = "";
		generalProxyPort = 80;
		generalProxyEnabled = false;
		optionRecursive = false;
		screenSettings = new ScreenSettings();
		localSourcesFolders = new ArrayList<File>();
		serieSourceAddic7ed = true;
		serieSourceTvSubtitles = true;
		serieSourcePodnapisi = true;
		serieSourceOpensubtitles = true;
		serieSourceLocal = true;
		autoUpdateMapping = false;
		setOptionSubtitleExactMatch(true);
		setOptionSubtitleKeywordMatch(true);	
		setOptionNoResultShowItAll(true);	
		setProcessEpisodeSource(SettingsProcessEpisodeSource.BIERDOPJE);
	}

	public boolean isOptionsAlwaysConfirm() {
		return optionsAlwaysConfirm;
	}

	public void setOptionsAlwaysConfirm(boolean optionsAlwaysConfirm) {
		this.optionsAlwaysConfirm = optionsAlwaysConfirm;
	}

	public boolean isOptionsShowOnlyFound() {
		return optionsShowOnlyFound;
	}

	public void setOptionsShowOnlyFound(boolean optionsShowOnlyFound) {
		this.optionsShowOnlyFound = optionsShowOnlyFound;
	}

	public void setLastOutputDir(File lastOutputDir) {
		this.lastOutputDir = lastOutputDir;
	}

	public File getLastOutputDir() {
		return lastOutputDir;
	}

	public List<MappingBierdopjeScene> getMappingList() {
		return mappingList;
	}

	public void setMappingList(List<MappingBierdopjeScene> mappingList) {
		this.mappingList = mappingList;
	}

	public void setExcludeList(List<SettingsExcludeItem> excludeList) {
		this.excludeList = excludeList;
	}

	public List<SettingsExcludeItem> getExcludeList() {
		return excludeList;
	}

	public void setOptionsStopOnSearchError(boolean optionsStopOnSearchError) {
		this.optionsStopOnSearchError = optionsStopOnSearchError;
	}

	public boolean isOptionsStopOnSearchError() {
		return optionsStopOnSearchError;
	}

	public void setQualityRuleList(List<String> qualityRuleList) {
		this.qualityRuleList = qualityRuleList;
	}

	public List<String> getQualityRuleList() {
		return qualityRuleList;
	}

	public void setOptionsNoRuleMatchMatchTakeFirst(
			boolean optionsNoRuleMatchMatchTakeFirst) {
		this.optionsNoRuleMatchTakeFirst = optionsNoRuleMatchMatchTakeFirst;
	}

	public boolean isOptionsNoRuleMatchTakeFirst() {
		return optionsNoRuleMatchTakeFirst;
	}

	public void setOptionsAutomaticDownloadSelection(
			boolean optionsAutomaticDownloadSelection) {
		this.optionsAutomaticDownloadSelection = optionsAutomaticDownloadSelection;
	}

	public boolean isOptionsAutomaticDownloadSelection() {
		return optionsAutomaticDownloadSelection;
	}

	public void setEpisodeLibrarySettings(LibrarySettings episodeLibrarySettings) {
		this.episodeLibrarySettings = episodeLibrarySettings;
	}

	public LibrarySettings getEpisodeLibrarySettings() {
		return episodeLibrarySettings;
	}

	public void setMovieLibrarySettings(LibrarySettings movieLibrarySettings) {
		this.movieLibrarySettings = movieLibrarySettings;
	}

	public LibrarySettings getMovieLibrarySettings() {
		return movieLibrarySettings;
	}

	public String getGeneralProxyHost() {
		return generalProxyHost;
	}

	public void setGeneralProxyHost(String generalProxyHost) {
		this.generalProxyHost = generalProxyHost;
	}

	public int getGeneralProxyPort() {
		return generalProxyPort;
	}

	public void setGeneralProxyPort(int generalProxyPort) {
		this.generalProxyPort = generalProxyPort;
	}

	public boolean isGeneralProxyEnabled() {
		return generalProxyEnabled;
	}

	public void setGeneralProxyEnabled(boolean generalProxyEnabled) {
		this.generalProxyEnabled = generalProxyEnabled;
	}

	public void setDefaultIncomingFolders(List<File> defaultIncomingFolders) {
		this.defaultIncomingFolders = defaultIncomingFolders;
	}

	public List<File> getDefaultIncomingFolders() {
		return defaultIncomingFolders;
	}

	public void setOptionRecursive(boolean optionRecursive) {
		this.optionRecursive = optionRecursive;
	}

	public boolean isOptionRecursive() {
		return optionRecursive;
	}

	public ScreenSettings getScreenSettings() {
		return screenSettings;
	}

	public void setScreenSettings(ScreenSettings screenSettings) {
		this.screenSettings = screenSettings;
	}

	public void setLoginAddic7edEnabled(boolean loginAddic7edEnabled) {
		this.loginAddic7edEnabled = loginAddic7edEnabled;
	}

	public boolean isLoginAddic7edEnabled() {
		return this.loginAddic7edEnabled;
	}

	public void setLoginAddic7edUsername(String loginAddic7edUsername) {
		this.loginAddic7edUsername = loginAddic7edUsername;
	}

	public String getLoginAddic7edUsername() {
		return this.loginAddic7edUsername;
	}

	public void setLoginAddic7edPassword(String loginAddic7edPassword) {
		this.loginAddic7edPassword = loginAddic7edPassword;
	}

	public String getLoginAddic7edPassword() {
		return this.loginAddic7edPassword;
	}

	/**
	 * @return the localSourcesFolders
	 */
	public List<File> getLocalSourcesFolders() {
		return localSourcesFolders;
	}

	/**
	 * @param localSourcesFolders
	 *            the localSourcesFolders to set
	 */
	public void setLocalSourcesFolders(List<File> localSourcesFolders) {
		this.localSourcesFolders = localSourcesFolders;
	}

	/**
	 * @return the serieSourceAddic7ed
	 */
	public boolean isSerieSourceAddic7ed() {
		return serieSourceAddic7ed;
	}

	/**
	 * @param serieSourceAddic7ed the serieSourceAddic7ed to set
	 */
	public void setSerieSourceAddic7ed(boolean serieSourceAddic7ed) {
		this.serieSourceAddic7ed = serieSourceAddic7ed;
	}

	/**
	 * @return the serieSourceTvSubtitles
	 */
	public boolean isSerieSourceTvSubtitles() {
		return serieSourceTvSubtitles;
	}

	/**
	 * @param serieSourceTvSubtitles the serieSourceTvSubtitles to set
	 */
	public void setSerieSourceTvSubtitles(boolean serieSourceTvSubtitles) {
		this.serieSourceTvSubtitles = serieSourceTvSubtitles;
	}

	/**
	 * @return the serieSourcePodnapisi
	 */
	public boolean isSerieSourcePodnapisi() {
		return serieSourcePodnapisi;
	}

	/**
	 * @param serieSourcePodnapisi the serieSourcePodnapisi to set
	 */
	public void setSerieSourcePodnapisi(boolean serieSourcePodnapisi) {
		this.serieSourcePodnapisi = serieSourcePodnapisi;
	}

	/**
	 * @return the serieSourceOpensubtitles
	 */
	public boolean isSerieSourceOpensubtitles() {
		return serieSourceOpensubtitles;
	}

	/**
	 * @param serieSourceOpensubtitles the serieSourceOpensubtitles to set
	 */
	public void setSerieSourceOpensubtitles(boolean serieSourceOpensubtitles) {
		this.serieSourceOpensubtitles = serieSourceOpensubtitles;
	}

	/**
	 * @return the serieSourceLocal
	 */
	public boolean isSerieSourceLocal() {
		return serieSourceLocal;
	}

	/**
	 * @param serieSourceLocal the serieSourceLocal to set
	 */
	public void setSerieSourceLocal(boolean serieSourceLocal) {
		this.serieSourceLocal = serieSourceLocal;
	}

	/**
	 * @return the autoUpdateMapping
	 */
	public boolean isAutoUpdateMapping() {
		return autoUpdateMapping;
	}

	/**
	 * @param autoUpdateMapping the autoUpdateMapping to set
	 */
	public void setAutoUpdateMapping(boolean autoUpdateMapping) {
		this.autoUpdateMapping = autoUpdateMapping;
	}

	/**
	 * @return the optionSubtitleExactMatch
	 */
	public boolean isOptionSubtitleExactMatch() {
		return optionSubtitleExactMatch;
	}

	/**
	 * @param optionSubtitleExactMatch the optionSubtitleExactMatch to set
	 */
	public void setOptionSubtitleExactMatch(boolean optionSubtitleExactMatch) {
		this.optionSubtitleExactMatch = optionSubtitleExactMatch;
	}

	/**
	 * @return the optionSubtitleKeywordMatch
	 */
	public boolean isOptionSubtitleKeywordMatch() {
		return optionSubtitleKeywordMatch;
	}

	/**
	 * @param optionSubtitleKeywordMatch the optionSubtitleKeywordMatch to set
	 */
	public void setOptionSubtitleKeywordMatch(boolean optionSubtitleKeywordMatch) {
		this.optionSubtitleKeywordMatch = optionSubtitleKeywordMatch;
	}

	/**
	 * @return the optionNoResultShowItAll
	 */
	public boolean isOptionNoResultShowItAll() {
		return optionNoResultShowItAll;
	}

	/**
	 * @param optionNoResultShowItAll the optionNoResultShowItAll to set
	 */
	public void setOptionNoResultShowItAll(boolean optionNoResultShowItAll) {
		this.optionNoResultShowItAll = optionNoResultShowItAll;
	}

	/**
	 * @return the processEpisodeSource
	 */
	public SettingsProcessEpisodeSource getProcessEpisodeSource() {
		return processEpisodeSource;
	}

	/**
	 * @param processEpisodeSource the processEpisodeSource to set
	 */
	public void setProcessEpisodeSource(SettingsProcessEpisodeSource processEpisodeSource) {
		this.processEpisodeSource = processEpisodeSource;
	}

}